# $Id: PKGBUILD 180917 2013-03-28 02:20:12Z bisson $
# Maintainer: Gaetan Bisson <bisson@archlinux.org>
# Contributor: Eric Bélanger <eric@archlinux.org>

pkgname=procps-ng
pkgver=3.3.7
pkgrel=1
pkgdesc='Utilities for monitoring your system and its processes'
url='http://gitorious.org/procps'
license=('GPL' 'LGPL')
arch=('i686' 'x86_64' sh4)
groups=('base')
depends=('ncurses')
backup=('etc/sysctl.conf')
source=("procps-ng-${pkgver}.tar.gz::http://gitorious.org/procps/procps/archive-tarball/v${pkgver}"
        'sysctl.conf')

conflicts=('procps')
provides=('procps')
replaces=('procps')

options=('!libtool')

build() {
	cd "${srcdir}/procps-procps"
	echo ${pkgver} > .tarball-version
	./autogen.sh
	./configure --exec-prefix=/ --prefix=/usr --sysconfdir=/etc --libdir=/usr/lib
	make
}

package() {
	cd "${srcdir}/procps-procps"
	make DESTDIR="${pkgdir}" install
	install -D -m644 ../sysctl.conf "${pkgdir}/etc/sysctl.conf"

	# provided by util-linux
	rm "${pkgdir}/bin/kill"
	rm "${pkgdir}/usr/share/man/man1/kill.1"
}
sha1sums=('436ce9e585210340ff1673157e402e07879a6239'
          '29a4a031dc46e368b617503ea6eb15809c69468c')
